import request from "@/request/index.js";
//入驻认证
export function getSettled(data){
	return request('/front/landlord/houseUserAuth/addHouseUserAuth','post',data)
}
//个人信息详情页
export function getUserInfo(){
	return request('/front/broker/userInfo','get',null)
}
//退出登录
export function quitLogin(){
	return request('/front/broker/logout','get',null)
}
//注销账号
export function cancelUser(){
	return request('/front/close/account','delete',null)
}
//周战绩和月战绩
export function getAchievement(){
	return request('/front/app/broker/achievement','get',null)
}
//获取经纪人认证信息
export function getUserInfoAuth(){
	return request('/front/broker/userInfoAuth','get',null)
}
//全部租约
export function getLeaseList(){
	return request('/front/app/broker/lease/list','get',null)
}
//租约详情
export function getLeaseInfo(data){
	return request('/front/app/broker/lease/getInfo','post',data)
}
//租约详情未收费用/已收费用
export function getTenBill(data){
	return request('/front/app/broker/lease/getTenBill','post',data)
}
//房东待确认
export function getlandlordConfirm(data){
	return request('/front/app/broker/lease/getlandlordConfirm','post',data)
}


//  房屋转租申请列表

export function getSublet(pageNum,subletApplyState){
	return request(`/front/broker/sublet/list?pageNum=${pageNum}&pageSize=100&subletApplyState=${subletApplyState}`,'get',null)
}
// 取消转租

export function putSubLease(data) {
	return request('/front/broker/sublet','put',data)
} 
// 再次申请转租
export function putSublet(data) {
	return request('/front/landlord/sublet','put',data)
} 
//经纪人分战绩详情列表

export function achievementList(startTime,endTime,achievType) {
	return request(`/front/app/broker/achievement/list?startTime=${startTime}&endTime=${endTime}&achievType=${achievType}`,'get',null)
} 

// 获取消息未读数
export function getUnreadNum(informationType){
	return request(`/front/broker/information/getUnreadNum?informationType=${informationType}`,'get',null)
}

// 消息已读
export function haveRead(data){
	return request(`/front/broker/information/haveRead`,'put',data)
}
// 转租详情
export function sublet(id){
	return request(`/front/broker/sublet/${id}`,'get',null)
}